package stringMVC.model;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RequestMapping("/calc")
@RestController
public class Calculate {
    @RequestMapping("/sum")
    public String sum(@RequestParam("num1") Integer a, @RequestParam("num2")Integer b){
        Integer sum = a + b;
        return ""+sum;
    }
}
